![]() |
OPC-UA Embedded Server SDK
2.1.0
|
Functions | |
| UA_Status_t | UAServer_New_connection (uint64_t connection_id) |
| UA_Status_t | UAServer_Connection_closed (uint64_t connection_id) |
| void | UAServer_Callback_close_connection (uint64_t connection_id) |
| UA_Status_t | UAServer_New_data_received (void *read_context, uint64_t connection_id) |
| bool_t | UAServer_Callback_data_receive (void *application_context, uint64_t connection_id, uint8_t *buffer, uint32_t max_length_in_bytes, uint32_t *no_of_bytes_received) |
| UA_Status_t | UAServer_Get_data_to_send (void *write_context, uint64_t connection_id) |
| bool_t | UAServer_Callback_data_send (void *application_context, uint64_t connection_id, uint8_t *buffer, uint32_t no_of_bytes_to_send, uint32_t *no_of_bytes_sent) |
| UA_Status_t | UAServer_Ready_to_receive (uint64_t connection_id, bool_t *result) |
| UA_Status_t UAServer_New_connection | ( | uint64_t | connection_id | ) |
Informs the library that a new TCPIP connection has been made
Whenever a new TCPIP connection is made on the UA Server listening TCP PORT the host must call this function.
| [in] | connection_id | A unique identifier for this TCPIP connection. Where a socket API is in use the socket file descriptor may be used. Where a raw API is in use a value representing the remote endpoint may be used. |
| UA_Status_t UAServer_Connection_closed | ( | uint64_t | connection_id | ) |
Informs the library that a TCPIP connection has been terminated
Whenever a TCPIP connection is closed or aborted on the UA Server listening TCP PORT the host must call this function.
| [in] | connection_id | A unique identifier for this TCPIP connection. Where a socket API is in use the socket file descriptor may be used. Where a raw API is in use a value representing the remote endpoint may be used. |
| void UAServer_Callback_close_connection | ( | uint64_t | connection_id | ) |
Instructs the host application to close the socket
Whenever a TCP Binary connection is closed the library informs the host application to close the corresponding socket.
| [in] | connection_id | A unique identifier for this TCPIP connection. Where a socket API is in use the socket file descriptor may be used. Where a raw API is in use a value representing the remote endpoint may be used. |
| UA_Status_t UAServer_New_data_received | ( | void * | read_context, |
| uint64_t | connection_id | ||
| ) |
Informs the library that new data has been received
Whenever new data is received on a TCPIP connection the host must call this function. The library responds by calling UAServer_Callback_data_receive()
| [in] | read_context | A pointer to an application specific data structure providing context to the pending read operation. The library will pass this pointer to UAServer_Receive_data_callback(). |
| [in] | connection_id | A unique identifier for this TCPIP connection. Where a socket API is in use the socket file descriptor may be used. Where a raw API is in use a value representing the remote endpoint may be used. |
| bool_t UAServer_Callback_data_receive | ( | void * | application_context, |
| uint64_t | connection_id, | ||
| uint8_t * | buffer, | ||
| uint32_t | max_length_in_bytes, | ||
| uint32_t * | no_of_bytes_received | ||
| ) |
Read new data from TCP/IP stack
Whenever new data is received on an active TCPIP connection the library calls this function in response to UAServer_New_data_received()
| [in] | application_context | A pointer to an application specific data structure providing context to the pending read operation. The host must pass this pointer to UAServer_New_data_received(). |
| [in] | connection_id | A unique identifier for this TCPIP connection. Where a socket API is in use the socket file descriptor may be used. Where a raw API is in use a value representing the remote endpoint may be used. |
| [in] | buffer | A pointer to the data buffer |
| [in] | max_length_in_bytes | The maximum length of data to write into the buffer in bytes |
| [out] | no_of_bytes_received | The number of bytes read into the buffer |
| UA_Status_t UAServer_Get_data_to_send | ( | void * | write_context, |
| uint64_t | connection_id | ||
| ) |
Get queued data to send from the library
When the library has data queued for transmission this function is called in order to send the queued data. The library responds by calling UAServer_Callback_data_send()
| [in] | write_context | A pointer to an application specific data structure providing context to the pending read operation. The library will pass this pointer to UAServer_Send_data_callback(). |
| [in] | connection_id | A unique identifier for this TCPIP connection. Where a socket API is in use the socket file descriptor may be used. Where a raw API is in use a value representing the remote endpoint may be used. |
| bool_t UAServer_Callback_data_send | ( | void * | application_context, |
| uint64_t | connection_id, | ||
| uint8_t * | buffer, | ||
| uint32_t | no_of_bytes_to_send, | ||
| uint32_t * | no_of_bytes_sent | ||
| ) |
Send new data to TCP/IP stack
The library calls this function in response to UAServer_Get_data_to_send()
| [in] | application_context | A pointer to an application specific data structure providing context to the pending read operation. The host must pass this pointer to UAServer_Get_data_to_send(). |
| [in] | connection_id | A unique identifier for this TCPIP connection. Where a socket API is in use the socket file descriptor may be used. Where a raw API is in use a value representing the remote endpoint may be used. |
| [in] | buffer | Pointer to the buffer containing the data to send |
| [in] | no_of_bytes_to_send | The length of data available to send in bytes |
| [out] | no_of_bytes_sent | The number of data bytes sent. If this number equals the no_of_bytes_to_send the library may call the function again to send more data if available. |
| UA_Status_t UAServer_Ready_to_receive | ( | uint64_t | connection_id, |
| bool_t * | result | ||
| ) |
Can the connection receive any more data at present
| [in] | connection_id | A unique identifier for this TCPIP connection. Where a socket API is in use the socket file descriptor may be used. Where a raw API is in use a value representing the remote endpoint may be used. |
| [out] | result | True if the server can receive more data. |